<!DOCTYPE html>
<html class="writer-html5" lang="en" >
<head>
  <meta charset="utf-8" /><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" />

  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>Melodie Exceptions &mdash; Melodie 0.6.0 documentation</title>
      <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
      <link rel="stylesheet" href="../_static/css/theme.css" type="text/css" />
  <!--[if lt IE 9]>
    <script src="../_static/js/html5shiv.min.js"></script>
  <![endif]-->
  
        <script data-url_root="../" id="documentation_options" src="../_static/documentation_options.js"></script>
        <script src="../_static/jquery.js"></script>
        <script src="../_static/underscore.js"></script>
        <script src="../_static/_sphinx_javascript_frameworks_compat.js"></script>
        <script src="../_static/doctools.js"></script>
    <script src="../_static/js/theme.js"></script>
    <link rel="author" title="About these documents" href="../about.html" />
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="Change Log" href="../changelog.html" />
    <link rel="prev" title="DB" href="db.html" /> 
</head>

<body class="wy-body-for-nav"> 
  <div class="wy-grid-for-nav">
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search" >
            <a href="../index.html" class="icon icon-home"> Melodie
            <img src="../_static/logo.jpg" class="logo" alt="Logo"/>
          </a>
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>
        </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
              <ul class="current">
<li class="toctree-l1"><a class="reference internal" href="../installation.html">Installation</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../installation.html#user-installation">User Installation</a></li>
<li class="toctree-l2"><a class="reference internal" href="../installation.html#developer-installation">Developer Installation</a></li>
<li class="toctree-l2"><a class="reference internal" href="../installation.html#dependency-note">Dependency Note</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../introduction.html">Introduction</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../introduction.html#agent-based-model-abm">Agent-based Model (ABM)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../introduction.html#melodie-framework">Melodie Framework</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../introduction.html#model">Model</a></li>
<li class="toctree-l3"><a class="reference internal" href="../introduction.html#scenario">Scenario</a></li>
<li class="toctree-l3"><a class="reference internal" href="../introduction.html#modelling-manager">Modelling Manager</a></li>
<li class="toctree-l3"><a class="reference internal" href="../introduction.html#infrastructure">Infrastructure</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../tutorial.html">Tutorial</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#project-structure">Project Structure</a></li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#agent">Agent</a></li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#scenario">Scenario</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../tutorial.html#generate-agent-params">Generate <code class="docutils literal notranslate"><span class="pre">agent_params</span></code></a></li>
<li class="toctree-l3"><a class="reference internal" href="../tutorial.html#load-simulator-scenarios">Load <code class="docutils literal notranslate"><span class="pre">simulator_scenarios</span></code></a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#model">Model</a></li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#environment">Environment</a></li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#datacollector">DataCollector</a></li>
<li class="toctree-l2"><a class="reference internal" href="../tutorial.html#last-words">Last Words</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../framework_comparison.html">Framework Comparison</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../framework_comparison.html#project-structure">Project Structure</a></li>
<li class="toctree-l2"><a class="reference internal" href="../framework_comparison.html#model-components">Model Components</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#melodie">Melodie</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id2">Mesa</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id3">AgentPy</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#summary">Summary</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../framework_comparison.html#scenario-management">Scenario Management</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id4">Melodie</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id5">Mesa</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id6">AgentPy</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#id7">Summary</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../framework_comparison.html#modeling-manager">Modeling Manager</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#calibrator">Calibrator</a></li>
<li class="toctree-l3"><a class="reference internal" href="../framework_comparison.html#trainer">Trainer</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../gallery/_index.html">Model Gallery</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../gallery/covid_grid_contagion.html">CovidGridContagion</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_grid_contagion.html#project-structure">Project Structure</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_grid_contagion.html#grid-and-spot">Grid and Spot</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_grid_contagion.html#matrix-data">Matrix Data</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_grid_contagion.html#model">Model</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_grid_contagion.html#gridagent">GridAgent</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../gallery/covid_network_contagion.html">CovidNetworkContagion</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_network_contagion.html#project-structure">Project Structure</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_network_contagion.html#model">Model</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_network_contagion.html#scenario">Scenario</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../gallery/covid_contagion_calibrator.html">CovidContagionCalibrator</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_calibrator.html#project-structure">Project Structure</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_calibrator.html#calibrator">Calibrator</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_calibrator.html#algorithm">Algorithm</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_calibrator.html#results">Results</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../gallery/rock_paper_scissors.html">RockPaperScissorsTrainer</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../gallery/rock_paper_scissors.html#model-setup">Model Setup</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/rock_paper_scissors.html#trainer">Trainer</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/rock_paper_scissors.html#results">Results</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../gallery/covid_contagion_visual.html">CovidContagionVisual</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_visual.html#visualizer">Visualizer</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_visual.html#melodiestudio">MelodieStudio</a></li>
<li class="toctree-l3"><a class="reference internal" href="../gallery/covid_contagion_visual.html#how-to-start">How to start?</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../advanced/_index.html">Advanced Topics</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../advanced/troubleshooting.html">TroubleShooting</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../advanced/troubleshooting.html#port-already-in-use">Port Already in use</a><ul>
<li class="toctree-l4"><a class="reference internal" href="../advanced/troubleshooting.html#windows">Windows</a></li>
<li class="toctree-l4"><a class="reference internal" href="../advanced/troubleshooting.html#macos-linux-or-other-nix-systems">MacOS, Linux or other *nix systems</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../advanced/melodie_error_list.html">Melodie Errors</a></li>
</ul>
</li>
<li class="toctree-l1 current"><a class="reference internal" href="_index.html">API Reference</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="model.html">Model</a></li>
<li class="toctree-l2"><a class="reference internal" href="agent.html">Agent</a></li>
<li class="toctree-l2"><a class="reference internal" href="agent_list.html">AgentList</a></li>
<li class="toctree-l2"><a class="reference internal" href="environment.html">Environment</a></li>
<li class="toctree-l2"><a class="reference internal" href="data_collector.html">DataCollector</a></li>
<li class="toctree-l2"><a class="reference internal" href="grid.html">Grid</a></li>
<li class="toctree-l2"><a class="reference internal" href="network.html">Network</a></li>
<li class="toctree-l2"><a class="reference internal" href="data_info.html">DataInfo</a><ul>
<li class="toctree-l3"><a class="reference internal" href="data_info.html#dataframeinfo">DataFrameInfo</a></li>
<li class="toctree-l3"><a class="reference internal" href="data_info.html#matrixinfo">MatrixInfo</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="data_loader.html">DataLoader</a></li>
<li class="toctree-l2"><a class="reference internal" href="scenario.html">Scenario</a></li>
<li class="toctree-l2"><a class="reference internal" href="simulator.html">Simulator</a></li>
<li class="toctree-l2"><a class="reference internal" href="calibrator.html">Calibrator</a></li>
<li class="toctree-l2"><a class="reference internal" href="trainer.html">Trainer</a></li>
<li class="toctree-l2"><a class="reference internal" href="db.html">DB</a></li>
<li class="toctree-l2 current"><a class="current reference internal" href="#">Melodie Exceptions</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../changelog.html">Change Log</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../changelog.html#major-version-0-x">Major Version 0.x</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-6-0-jan-04-2023">v0.6.0 (Jan. 04, 2023)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-5-0-dec-17-2022">v0.5.0 (Dec. 17, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-4-2-dec-15-2022">v0.4.2 (Dec. 15, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-4-1-dec-12-2022">v0.4.1 (Dec. 12, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-4-0-nov-15-2022">v0.4.0 (Nov. 15, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-3-0-oct-28-2022">v0.3.0 (Oct. 28, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-2-0-oct-24-2022">v0.2.0 (Oct. 24, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-1-1-aug-23-2022">v0.1.1 (Aug. 23, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#v0-1-0-jul-22-2022">v0.1.0 (Jul. 22, 2022)</a></li>
<li class="toctree-l3"><a class="reference internal" href="../changelog.html#start-may-10-2021">Start (May. 10, 2021)</a></li>
</ul>
</li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../contribution.html">Contribution</a><ul>
<li class="toctree-l2"><a class="reference internal" href="../contribution.html#report-bugs">Report Bugs</a><ul>
<li class="toctree-l3"><a class="reference internal" href="../contribution.html#report-melodie-bugs">Report Melodie Bugs</a></li>
<li class="toctree-l3"><a class="reference internal" href="../contribution.html#report-documentation-bugs">Report Documentation Bugs</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../contribution.html#ask-for-functionalities">Ask for Functionalities</a></li>
<li class="toctree-l2"><a class="reference internal" href="../contribution.html#how-to-contribute">How to Contribute</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="../about.html">About</a></li>
</ul>

        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="../index.html">Melodie</a>
      </nav>

      <div class="wy-nav-content">
        <div class="rst-content">
          <div role="navigation" aria-label="Page navigation">
  <ul class="wy-breadcrumbs">
      <li><a href="../index.html" class="icon icon-home"></a> &raquo;</li>
          <li><a href="_index.html">API Reference</a> &raquo;</li>
      <li>Melodie Exceptions</li>
      <li class="wy-breadcrumbs-aside">
            <a href="../_sources/api/exceptions.rst.txt" rel="nofollow"> View page source</a>
      </li>
  </ul>
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
             
  <section id="module-MelodieInfra.exceptions.exceptions">
<span id="melodie-exceptions"></span><h1>Melodie Exceptions<a class="headerlink" href="#module-MelodieInfra.exceptions.exceptions" title="Permalink to this heading"></a></h1>
<dl class="py function">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.assert_exc_occurs">
<span class="sig-prename descclassname"><span class="pre">MelodieInfra.exceptions.exceptions.</span></span><span class="sig-name descname"><span class="pre">assert_exc_occurs</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">exc_id</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">func</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Callable</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.assert_exc_occurs" title="Permalink to this definition"></a></dt>
<dd><p>Assert that this exception will occur.</p>
</dd></dl>

<dl class="py function">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.assert_exc_type_occurs">
<span class="sig-prename descclassname"><span class="pre">MelodieInfra.exceptions.exceptions.</span></span><span class="sig-name descname"><span class="pre">assert_exc_type_occurs</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">exc_type</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">BaseException</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">func</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Callable</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.assert_exc_type_occurs" title="Permalink to this definition"></a></dt>
<dd><p>Assert that exception of <cite>exc_type</cite> must occur.</p>
</dd></dl>

<dl class="py exception">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieException">
<em class="property"><span class="pre">exception</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">MelodieInfra.exceptions.exceptions.</span></span><span class="sig-name descname"><span class="pre">MelodieException</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">exc_id</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">text</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieException" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">Exception</span></code></p>
</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">MelodieInfra.exceptions.exceptions.</span></span><span class="sig-name descname"><span class="pre">MelodieExceptions</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Assertions</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.Type">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Type</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">obj</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">expected_type</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.Type" title="Permalink to this definition"></a></dt>
<dd><p>Assert that the type of <cite>obj</cite> is the <cite>expected_type</cite>.</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.IsNone">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">IsNone</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.IsNone" title="Permalink to this definition"></a></dt>
<dd><p>Assert variable <cite>obj</cite> is None.</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.NotNone">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">NotNone</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Assertions.NotNone" title="Permalink to this definition"></a></dt>
<dd><p>Assert that the <cite>obj</cite> is not None</p>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.General">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">General</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.General" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.General.TypeError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">TypeError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">obj</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">expected_type</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">type</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.General.TypeError" title="Permalink to this definition"></a></dt>
<dd><p>The encapsulation of TypeError</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.General.NoAttributeError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">NoAttributeError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">attr_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.General.NoAttributeError" title="Permalink to this definition"></a></dt>
<dd><p>The encapsulation of AttributeError</p>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Program</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>Errors related to programming</p>
<ul class="simple">
<li><p>code: 1000</p></li>
</ul>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1000</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Variable</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1010</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.VariableInvalid">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">VariableInvalid</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">var_desc</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">var_value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">expected_value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.VariableInvalid" title="Permalink to this definition"></a></dt>
<dd><p>If this occurs, please check the value of variable</p>
<ul class="simple">
<li><p>code: 1011</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.VariableNotInSet">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">VariableNotInSet</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">var_desc</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">var_value</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Any</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">allowed_set</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Set</span><span class="p"><span class="pre">[</span></span><span class="pre">Any</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Variable.VariableNotInSet" title="Permalink to this definition"></a></dt>
<dd><p>Please check if variable is in the allowed set.</p>
<ul class="simple">
<li><p>code: 1012</p></li>
<li><p>example: If the allowed set is {“apple”, “pears”}, but the variable value is “banana”</p></li>
</ul>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Function</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1020</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function.FunctionArgsNumError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">FunctionArgsNumError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">func</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Callable</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">expected_arg_num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">actual_arg_num</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Program.Function.FunctionArgsNumError" title="Permalink to this definition"></a></dt>
<dd><p>Function should have correct number of arguments. If not, this error will be raised.</p>
<ul class="simple">
<li><p>code: 1021</p></li>
<li><p>example: Expecting 1 argument, but the function was <code class="docutils literal notranslate"><span class="pre">lambda</span> <span class="pre">a,</span> <span class="pre">b:</span> <span class="pre">a+b</span></code></p></li>
</ul>
</dd></dl>

</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.State">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">State</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.State" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.State.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1100</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.State.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.State.StateNotFoundError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">StateNotFoundError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">state</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_states</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.State.StateNotFoundError" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.State.CannotMoveToNewStateError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">CannotMoveToNewStateError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">old_state</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">new_state</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_possible_new_states</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">set</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.State.CannotMoveToNewStateError" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.State.NotAStateAttributeError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">NotAStateAttributeError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">agent_cls</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">state_attr</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.State.NotAStateAttributeError" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Scenario</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1200</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ScenarioIDDuplicatedError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ScenarioIDDuplicatedError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">id_scenario</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ScenarioIDDuplicatedError" title="Permalink to this definition"></a></dt>
<dd><p>Scenario ID should be unique. If there are identical scenario-id in the scenario table or generated,
this error will be raised.</p>
<ul class="simple">
<li><p>code: 1201</p></li>
<li><p>example: The scenario table below could make this error occur.</p></li>
</ul>
<table class="colwidths-given docutils align-default" id="id1">
<caption><span class="caption-text">Scenarios</span><a class="headerlink" href="#id1" title="Permalink to this table"></a></caption>
<colgroup>
<col style="width: 25%" />
<col style="width: 25%" />
<col style="width: 25%" />
<col style="width: 25%" />
</colgroup>
<thead>
<tr class="row-odd"><th class="head"><p>ID</p></th>
<th class="head"><p>env_param_1</p></th>
<th class="head"><p>env_param_2</p></th>
<th class="head"><p>…</p></th>
</tr>
</thead>
<tbody>
<tr class="row-even"><td><p>0</p></td>
<td><p>10</p></td>
<td><p>20</p></td>
<td><p>…</p></td>
</tr>
<tr class="row-odd"><td><p>0</p></td>
<td><p>15</p></td>
<td><p>20</p></td>
<td><p>…</p></td>
</tr>
</tbody>
</table>
<p>In this table, the ids of scenarios are identical, which will cause this exception.</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ScenarioIDTypeError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ScenarioIDTypeError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">id_scenario</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ScenarioIDTypeError" title="Permalink to this definition"></a></dt>
<dd><p>Scenario ID should be integer type.</p>
<ul class="simple">
<li><p>code: 1202</p></li>
<li><p>hint: Please check carefully to make sure the scenario id is integer.</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.NoValidScenarioGenerated">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">NoValidScenarioGenerated</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">scenarios</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.NoValidScenarioGenerated" title="Permalink to this definition"></a></dt>
<dd><p>Operators (Simulator/Trainer/Calibrator) will generate a list of scenarios.
If no scenario has been generated, this error will be raised.</p>
<ul class="simple">
<li><p>code: 1204</p></li>
</ul>
<p>Hint:</p>
<ul class="simple">
<li><p>If you overrode the <code class="docutils literal notranslate"><span class="pre">generate_scenarios</span></code> method of DataframeLoader, make sure valid value returned.</p></li>
<li><p>If you are using <code class="docutils literal notranslate"><span class="pre">xlsx</span></code> tables, make sure the first page of <code class="docutils literal notranslate"><span class="pre">&lt;operator_type&gt;_scenarios.xlsx</span></code>
is not empty.</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ParameterRedefinedError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ParameterRedefinedError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">parameter_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_params</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Scenario.ParameterRedefinedError" title="Permalink to this definition"></a></dt>
<dd><p>For the interactive parameters of Scenario, the name should be unique.
If two parameters has the same name, this exception will be raised.</p>
<ul class="simple">
<li><p>code: 1205</p></li>
</ul>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Agents</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1300</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentListEmpty">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">AgentListEmpty</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">agent_manager</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentListEmpty" title="Permalink to this definition"></a></dt>
<dd><ul class="simple">
<li><p>code: 1301</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentPropertyNameNotExist">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">AgentPropertyNameNotExist</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">property_name</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">agent</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentPropertyNameNotExist" title="Permalink to this definition"></a></dt>
<dd><ul class="simple">
<li><p>code: 1302</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentIDConflict">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">AgentIDConflict</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">agent_container_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">agent_ids</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Agents.AgentIDConflict" title="Permalink to this definition"></a></dt>
<dd><p>Agent ID should be unique.</p>
<ul class="simple">
<li><p>code: 1303</p></li>
</ul>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Environment">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Environment</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Environment" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Environment.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1400</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Environment.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Data</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>This class is used when external data is imported or exported.</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1500</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNameAlreadyExists">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">TableNameAlreadyExists</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">table_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">existed</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNameAlreadyExists" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.StaticTableNotRegistered">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">StaticTableNotRegistered</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">table_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_table_names</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.StaticTableNotRegistered" title="Permalink to this definition"></a></dt>
<dd><p>Static table should be registered before use.</p>
<ul class="simple">
<li><p>code: 1502</p></li>
<li><p>hint: Make sure this table is correctly registered in the DataLoader.</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.AttemptingReadingFromUnexistedTable">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">AttemptingReadingFromUnexistedTable</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">table_name</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.AttemptingReadingFromUnexistedTable" title="Permalink to this definition"></a></dt>
<dd><p>When reading the database, the table must exist in the database.
* code: 1503</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ObjectPropertyTypeUnMatchTheDataFrameError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ObjectPropertyTypeUnMatchTheDataFrameError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">param_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">param_type</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">type</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">dataframe_dtypes</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Dict</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">,</span></span><span class="w"> </span><span class="pre">type</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">agent</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="agent.html#Melodie.boost.basics.Agent" title="Melodie.boost.basics.Agent"><span class="pre">Agent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ObjectPropertyTypeUnMatchTheDataFrameError" title="Permalink to this definition"></a></dt>
<dd><p>Object type should match the type defined in dataframe.</p>
<ul class="simple">
<li><p>code: 1504</p></li>
<li><p>example: If the dataframe has type float, and agent property was str.</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNameInvalid">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">TableNameInvalid</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">table_name</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNameInvalid" title="Permalink to this definition"></a></dt>
<dd><p>The table name should be an identifier.</p>
<ul class="simple">
<li><p>code: 1505</p></li>
<li><p>hint: Do not use “+”, “-”, “*”, “/” or other special characters.</p></li>
<li><p>example: <code class="docutils literal notranslate"><span class="pre">table-123</span></code>; <code class="docutils literal notranslate"><span class="pre">table+123</span></code></p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNotFound">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">TableNotFound</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">table_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_tables</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">dict</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.TableNotFound" title="Permalink to this definition"></a></dt>
<dd><p>Table may not be registered.</p>
<ul class="simple">
<li><p>code: 1506</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.InvalidDatabaseType">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">InvalidDatabaseType</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">database</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">supported_db_types</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Set</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.InvalidDatabaseType" title="Permalink to this definition"></a></dt>
<dd><ul class="simple">
<li><p>code: 1508</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.NoDataframeLoaderDefined">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">NoDataframeLoaderDefined</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.NoDataframeLoaderDefined" title="Permalink to this definition"></a></dt>
<dd><p>Dataframe Loader must be defined if you want to use the static table.</p>
<ul class="simple">
<li><p>code: 1509</p></li>
</ul>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ColumnNameConsistencyError">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ColumnNameConsistencyError</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">df_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">missing</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Set</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em>, <em class="sig-param"><span class="n"><span class="pre">undefined</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Set</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Data.ColumnNameConsistencyError" title="Permalink to this definition"></a></dt>
<dd><p>The column name in code should be consistent to the table.</p>
<ul class="simple">
<li><p>code: 1510</p></li>
</ul>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Tools</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>This class is for errors related to dev tools such as MelodieStudio</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1600</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools.MelodieStudioUnAvailable">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">MelodieStudioUnAvailable</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Tools.MelodieStudioUnAvailable" title="Permalink to this definition"></a></dt>
<dd><p>Melodie studio must be started before visualizer process start.</p>
<ul class="simple">
<li><p>code: 1601</p></li>
</ul>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Visualizer</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>This class is for errors related to visualizer.</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1700</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">Charts</span></span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts.ID">
<span class="sig-name descname"><span class="pre">ID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1700</span></em><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts.ID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts.ChartNameAlreadyDefined">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">ChartNameAlreadyDefined</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">chart_name</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">all_chart_names</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#MelodieInfra.exceptions.exceptions.MelodieExceptions.Visualizer.Charts.ChartNameAlreadyDefined" title="Permalink to this definition"></a></dt>
<dd><ul class="simple">
<li><p>code: 1701</p></li>
</ul>
</dd></dl>

</dd></dl>

</dd></dl>

</dd></dl>

</section>


           </div>
          </div>
          <footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
        <a href="db.html" class="btn btn-neutral float-left" title="DB" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
        <a href="../changelog.html" class="btn btn-neutral float-right" title="Change Log" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
    </div>

  <hr/>

  <div role="contentinfo">
    <p>&#169; Copyright 2021-2022, ABM4ALL.</p>
  </div>

  Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
    <a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
    provided by <a href="https://readthedocs.org">Read the Docs</a>.
   

</footer>
        </div>
      </div>
    </section>
  </div>
  <script>
      jQuery(function () {
          SphinxRtdTheme.Navigation.enable(true);
      });
  </script> 

</body>
</html>